package zuoye;

import java.util.Scanner;

public class zy3 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入一个字符串");
        String s = sc.nextLine();
        System.out.println(s);

        int da = 0;
        int xiao = 0;
        int shu = 0;

        for (int i = 0; i < s.length(); i++) {
            char c = s.charAt(i);
            if (c >= 'A' && c <= 'Z') {
                da++;
            }
            if (c >= 'a' && c <= 'z') {
                xiao++;
            }
            if (c >= '0' && c <= '9') {
                shu++;
            }
        }
        System.out.println("大写出现的次数" + da);
        System.out.println("小写出现的次数" + xiao);
        System.out.println("数字出现的次数" + shu);

    }
}
